import {createApp} from 'vue'
import App from './App.vue'
import router, {setupRouter} from './router'
import {setupStore} from './store'
import {initHttpClient} from './webapi/HttpClient'
import config from './config'
import Antd from 'ant-design-vue';
import * as icons from '@ant-design/icons-vue'
import './styles/index.less';
import dayjs from 'dayjs';
import 'dayjs/locale/zh-cn';
dayjs.locale('zh-cn');

const app = createApp(App);
setupStore(app);
setupRouter(app);
initHttpClient(config, router);

app.use(Antd);
Object.keys(icons).forEach(key => {
    app.component(key, icons[key])
});

router.isReady().then(() => app.mount('#app'));
